package com.fjp.heartguard.ui.main

import androidx.fragment.app.Fragment
import androidx.fragment.app.FragmentManager
import androidx.fragment.app.FragmentPagerAdapter
import com.fjp.heartguard.ui.home.HomeFragment
import com.fjp.heartguard.ui.mine.MineFragment
import com.fjp.heartguard.ui.report.ReportsFragment

/**
 *Author:Mr'x
 *Time:2025/1/9
 *Description:
 */
class MainFragmentPagerAdapter(fm: FragmentManager) : FragmentPagerAdapter(fm) {
    private val fragments = arrayListOf(HomeFragment(), ReportsFragment(), MineFragment())

    override fun getCount(): Int {
        return fragments.size
    }

    override fun getItem(position: Int): Fragment {
        return fragments[position]
    }

}